#pragma once

    /* Converts the ID to role and profession ,return 0 if successful*/
    static int ID_To_PF_Convert(int id,int &role,int &profession){
        int role_bits=id>>16;
        int profession_bits=id&0xFFFF;
        role=role_bits;
        profession=profession_bits;
        return 0;
    };

    /* Converts the role and profession to ID, return 0 if successful*/
    static int PF_To_ID_Convert(int role,int profession,int &id){
        if(role<0 || profession<0){
            return -1; // Invalid role or profession
        }
        id=(role<<16) | (profession & 0xFFFF);
        return 0;
    };
